//    Copyright (C) Kherty.  All rights reserved.
using System.Windows.Data;
using OpenLS.Drawing.UI;
using OpenLS.Drawing.UI.Internals;

namespace OpenLS.Chart.UI.Internals
{
    public static class ChartConverters
    {
        static readonly ViewModelFactory _viewModelFactory = new ViewModelFactory();
        public static IValueConverter ViewModelFactory { get { return _viewModelFactory; } }
        static readonly AxisInfoFactory _axisInfoFactory = new AxisInfoFactory();
        public static IMultiValueConverter AxisInfoFactory { get { return _axisInfoFactory; } }
        static readonly Axis3DInfoFactory _axis3DInfoFactory = new Axis3DInfoFactory();
        public static IMultiValueConverter Axis3DInfoFactory { get { return _axis3DInfoFactory; } }
        static readonly SimpleAxisInfoFactory _simpleAxisInfoFactory = new SimpleAxisInfoFactory();
        public static IValueConverter SimpleAxisInfoFactory { get { return _simpleAxisInfoFactory; } }
        private static readonly ThrottlingConverter<object> _objectThrottlingConverter = new ThrottlingConverter<object>();
        private static readonly ThrottlingConverter<NumericValue> _numericValueThrottlingConverter = new ThrottlingConverter<NumericValue>();
        static readonly InvertConverter _invertConverter = new InvertConverter();
        public static IValueConverter InvertConverter{get{ return _invertConverter;}}
        static readonly EnsureShapePropertiesConverter _ensureShapePropertiesConverter = new EnsureShapePropertiesConverter();
        public static IValueConverter EnsureShapePropertiesConverter{get{ return _ensureShapePropertiesConverter;}}
        static readonly HalfConverter _halfConverter = new HalfConverter();
        public static IValueConverter HalfConverter{get{ return _halfConverter;}}
        static readonly DataLabelConverter _dataLabelConverter = new DataLabelConverter();
        public static IMultiValueConverter DataLabelConverter{get{ return _dataLabelConverter;}}
        private static readonly PositionConverter _positionConverter = new PositionConverter();
        public static IValueConverter PositionConverter { get { return _positionConverter; } }
        static readonly MarkerStyleSizeToPathDataConverter _markerStyleSizeToPathDataConverter = new MarkerStyleSizeToPathDataConverter();
        public static  IMultiValueConverter MarkerStyleSizeToPathDataConverter{get{ return _markerStyleSizeToPathDataConverter;}}
        static readonly MarkerAccessor _markerAccessor = new MarkerAccessor();
        public static IValueConverter MarkerAccessor { get { return _markerAccessor; } }
        static readonly NumericValueToTooltipConverter _numericValueToTooltipConverter = new NumericValueToTooltipConverter();
        public static IMultiValueConverter NumericValueToTooltipConverter{get{ return _numericValueToTooltipConverter;}}
        static readonly LineDashPropertiesToStrokeDashArrayConverter _lineDashPropertiesToStrokeDashArrayConverter = new LineDashPropertiesToStrokeDashArrayConverter();
        public static IValueConverter LineDashPropertiesToStrokeDashArrayConverter{get{ return _lineDashPropertiesToStrokeDashArrayConverter;}}
        static readonly FillColorBaseSchemeToBrushConverter _fillColorBaseSchemeToBrushConverter = new FillColorBaseSchemeToBrushConverter();
        public static IMultiValueConverter FillColorBaseSchemeToBrushConverter{get{ return _fillColorBaseSchemeToBrushConverter;}}
        static readonly ForceUnitConverter _forceUnitConverter = new ForceUnitConverter();
        public static IValueConverter ForceUnitConverter{get{return _forceUnitConverter;}}
        static readonly OrConverter _orConverter = new OrConverter();
        public static IMultiValueConverter OrConverter { get { return _orConverter; } }
        private static OrConverter _orSkipNullConverter;
        public static IMultiValueConverter OrSkipNullConverter
        {
            get
            {
                if (_orSkipNullConverter == null)
                    _orSkipNullConverter = new OrConverter { SkipNull = true };
                return _orSkipNullConverter;
            }
        }
        private static readonly OrientationToBooleanConverter _orientationToBooleanConverter = new OrientationToBooleanConverter();
        public static IValueConverter  OrientationToBooleanConverter{get{ return _orientationToBooleanConverter;}}
        static readonly ChartInfoFactory _chartInfoFactory = new ChartInfoFactory();
        public static IMultiValueConverter ChartInfoFactory{get{ return _chartInfoFactory;}}

        static readonly EnumEnumerator _enumEnumerator = new EnumEnumerator();
        public static IValueConverter EnumEnumerator { get { return _enumEnumerator; } }

        static readonly FormattingConverter _formattingConverter = new FormattingConverter();
        public static IMultiValueConverter FormattingConverter { get { return _formattingConverter; } }

        static readonly MinMaxToInfoConverter _minMaxToMajorInfoConverter = new MinMaxToInfoConverter(6);
        public static IMultiValueConverter MinMaxToMajorInfoConverter { get { return _minMaxToMajorInfoConverter; } }

        static readonly MinMaxToInfoConverter _minMaxToMinorInfoConverter = new MinMaxToInfoConverter(30);
        public static IMultiValueConverter MinMaxToMinorInfoConverter { get { return _minMaxToMinorInfoConverter; } }

        static readonly ProjectorFactory _projectorFactory = new ProjectorFactory();
        public static IMultiValueConverter ProjectorFactory { get { return _projectorFactory; } }

        static readonly CameraXYZToXConverter _cameraXyztoXConverter = new CameraXYZToXConverter();
        public static IMultiValueConverter CameraXYZToXConverter { get { return _cameraXyztoXConverter; } }

        static readonly CameraXYZToYConverter _cameraXyztoYConverter = new CameraXYZToYConverter();
        public static IMultiValueConverter CameraXYZToYConverter { get { return _cameraXyztoYConverter; } }




        static readonly CountAndGroupingToZMinimumConverter _countAndGroupingToZMinimumConverter = new CountAndGroupingToZMinimumConverter();
        public static IMultiValueConverter CountAndGroupingToZMinimumConverter { get { return _countAndGroupingToZMinimumConverter; } }
        static readonly CountAndGroupingToZAxisInfoConverter _countAndGroupingToAxisInfoConverter = new CountAndGroupingToZAxisInfoConverter();
        public static IMultiValueConverter CountAndGroupingToZAxisInfoConverter { get { return _countAndGroupingToAxisInfoConverter; } }
        
        static readonly ShapePropertiesObserverFactory _shapePropertiesObserverFactory = new ShapePropertiesObserverFactory();
        public static IValueConverter ShapePropertiesObserverFactory { get { return _shapePropertiesObserverFactory; } }
        static readonly EnumToNameConverter _enumToNameConverter = new EnumToNameConverter();
        public static IValueConverter EnumToNameConverter { get { return _enumToNameConverter; } }
        static readonly IsOfTypeConverter _isOfTypeConverter = new IsOfTypeConverter();
        public static IValueConverter IsOfTypeConverter
        {
            get
            {
                return _isOfTypeConverter;}}
        static readonly Bar3DModelFactory _bar3DModelFactory = new Bar3DModelFactory();
        public static IMultiValueConverter Bar3DModelFactory { get { return _bar3DModelFactory; } }
        static readonly SurfaceFactory _surfaceFactory = new SurfaceFactory();
        public static IMultiValueConverter SurfaceFactory { get { return _surfaceFactory; } }
        static readonly Area3DModelFactory _area3DModelFactory = new Area3DModelFactory();
        public static IMultiValueConverter Area3DModelFactory { get { return _area3DModelFactory; } }

        static readonly Line3DModelFactory _line3DModelFactory = new Line3DModelFactory();
        public static IMultiValueConverter Line3DModelFactory { get { return _line3DModelFactory; } }
        static readonly CameraConverter _cameraConverter = new CameraConverter();
        public static IMultiValueConverter CameraConverter
        {get{ return _cameraConverter;}}
        static readonly DataPointsAccessor _dataPointsAccessor = new DataPointsAccessor();
        public static IMultiValueConverter DataPointsAccessor
        { get { return _dataPointsAccessor; } }
        static readonly DataPointsObserverFactory _dataPointsObserverFactory = new DataPointsObserverFactory();
        public static IValueConverter DataPointsObserverFactory
        { get { return _dataPointsObserverFactory; } }
        static readonly MinMaxToStepConverter _minMaxToMajorStepConverter = new MinMaxToStepConverter(6);
        public static IMultiValueConverter MinMaxToMajorStepConverter
        { get { return _minMaxToMajorStepConverter; } }

        static readonly MinMaxToStepConverter _minMaxToMinorStepConverter = new MinMaxToStepConverter(30);
        public static IMultiValueConverter MinMaxToMinorStepConverter
        { get { return _minMaxToMinorStepConverter; } }



        static readonly MinMaxToValuesConverter _minMaxToValuesConverter = new MinMaxToValuesConverter();
        public static IMultiValueConverter MinMaxToValuesConverter
        { get {
            return _minMaxToValuesConverter; } }
        static readonly FillPropertiesToBrushConverter _fillPropertiesToBrushConverter = new FillPropertiesToBrushConverter();
        public static FillPropertiesToBrushConverter FillPropertiesToBrushConverter
        {
            get
            {
                return _fillPropertiesToBrushConverter;
            }

        }
        static readonly ColorBaseToBrushConverter _colorBaseToBrushConverter = new ColorBaseToBrushConverter();
        public static ColorBaseToBrushConverter ColorBaseToBrushConverter
        {
            get { return _colorBaseToBrushConverter; }
        }
        static readonly ChartAreaFillToBackgroundConverter _chartAreaFillToBackgroundConverter = new ChartAreaFillToBackgroundConverter();
        public static IMultiValueConverter ChartAreaFillToBackgroundConverter
        {
            get { return _chartAreaFillToBackgroundConverter; }
        }
        static readonly PlotAreaFillToBackgroundConverter _plotAreaFillToBackgroundConverter = new PlotAreaFillToBackgroundConverter();
        public static IMultiValueConverter PlotAreaFillToBackgroundConverter
        {
            get { return _plotAreaFillToBackgroundConverter; }
        }
        static readonly AreaSeriesToPointsConverter _areaSeriesToPointsConverter = new AreaSeriesToPointsConverter();
        public static IMultiValueConverter AreaSeriesToPointsConverter
        { get { return _areaSeriesToPointsConverter; } }

        static readonly LineSeriesToGeometryConverter _lineSeriesToGeometryConverter = new LineSeriesToGeometryConverter();
        public static IMultiValueConverter LineSeriesToGeometryConverter
        { get { return _lineSeriesToGeometryConverter; } }

        static readonly ScatterSeriesToGeometryConverter _scatterSeriesToGeometryConverter = new ScatterSeriesToGeometryConverter();
        public static IMultiValueConverter ScatterSeriesToGeometryConverter
        { get { return _scatterSeriesToGeometryConverter; } }
        
        static readonly PatternConverter _patternConverter = new PatternConverter();
        public static IMultiValueConverter PatternConverter
        {
            get { return _patternConverter; }
        }
        static readonly NumericValueToArcDataConverter _numericValueToArcDataConverter = new NumericValueToArcDataConverter();
        public static IMultiValueConverter NumericValueToArcDataConverter
        { get { return _numericValueToArcDataConverter; } }

        private static readonly ThemedElementToFillConverter _themedElementToFillConverter =
            new ThemedElementToFillConverter();
        public static IMultiValueConverter ThemedElementToFillConverter
        { get { return _themedElementToFillConverter; } }
        static readonly ThemeConverter _themeConverter = new ThemeConverter();
        public static ThemeConverter ThemeConverter
        { get { return _themeConverter; } }
        static readonly StrokeConverter _strokeConverter = new StrokeConverter();
        public static IMultiValueConverter StrokeConverter
        {
            get
            {
                return _strokeConverter;
            }
        }
        static readonly LineFillPropertiesSchemeIndexToBrushConverter _lineFillPropertiesSchemeIndexToBrushConverter = new LineFillPropertiesSchemeIndexToBrushConverter();
        public static IMultiValueConverter LineFillPropertiesSchemeIndexToBrushConverter{get{ return _lineFillPropertiesSchemeIndexToBrushConverter;}}
        static readonly ScalerFactory _scalerFactory = new ScalerFactory();
        public static IMultiValueConverter ScalerFactory
        {
            get
            {
                return _scalerFactory;
            }
        }
        static readonly ScatterChartObserverFactory _scatterChartObserverFactory = new ScatterChartObserverFactory();
        public static IValueConverter ScatterChartObserverFactory { get { return _scatterChartObserverFactory; } }
        static readonly ScatterSeriesObserverFactory _scatterSeriesObserverFactory = new ScatterSeriesObserverFactory();
        public static IValueConverter ScatterSeriesObserverFactory { get { return _scatterSeriesObserverFactory; } }
        static readonly SeriesObserverFactory _seriesObserverFactory = new SeriesObserverFactory();
        public static IMultiValueConverter SeriesObserverFactory
        { get { return _seriesObserverFactory; } }

        private static readonly IMultiValueConverter _effectConverter = DrawingConverters.EffectConverter;
        public static IMultiValueConverter EffectConverter
        { get { return _effectConverter; } }

        public static IMultiValueConverter NumValueThrottlingConverter
        {
            get { return _numericValueThrottlingConverter; }
        }
        public static IMultiValueConverter ValueThrottlingConverter
        {
            get { return _objectThrottlingConverter; }
        }
    }
}